package com.gzx.qc.modular.keyword.mapper;

import com.gzx.qc.modular.keyword.entity.GzxQaKeyword;
import com.gzx.qc.modular.keyword.entity.vo.GzxQaKeywordVo;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import vip.xiaonuo.common.mapper.BaseMapperPlus;

import java.util.List;

/**
 * @author zjt
 * @description
 * @since 2025/1/24 15:58
 */
public interface GzxQaKeywordMapper extends BaseMapperPlus<GzxQaKeyword, GzxQaKeywordVo> {

    @Insert("<script>" +
            "INSERT INTO gzx_qa_keyword (keyword, level, type, create_user, create_time,scope) " +
            "VALUES " +
            "<foreach collection='qaKeywordList' item='item' separator=','>" +
            "(#{item.keyword}, #{item.level}, #{item.type}, #{item.createUser}, #{item.createTime},#{item.scope})" +
            "</foreach>" +
            "</script>")
    void insertBatch(@Param("qaKeywordList") List<GzxQaKeyword> qaKeywordList);
}
